import { ComboBox } from "std-widgets.slint";
export component SelectItem {
    in property <string> label;
    in-out property <string> value;
    in property <[string]> model;
    HorizontalLayout {
        spacing: 4px;
        Rectangle {
            width: 64px;
            height: 36px;
            Text {
                width: 64px;
                horizontal-alignment: TextHorizontalAlignment.left;
                font-size: 18px;
                text: root.label;
            }
        }

        Rectangle {
            border-color: #aaa;
            border-width: 1px;
            border-radius: 5px;
            width: 480px;
            height: 36px;
            ComboBox {
                width: 100%;
                height: 100%;
                current-value: value;
                model: model;
                selected => {
                    root.value = self.current-value;
                }
            }
        }
    }
}
